﻿using System;
using System.Collections.Generic;
using ExpenseSystem.Common.BaseModel;

namespace ExpenseSystem.Model
{
    [TableName("EXP_SALESBONUS")]
    public class SalesBonusModel : NormalModel
    {
        private string _code;
        private long _salesid;
        private long _orderid;
        private decimal _bonus;
        private decimal _calbase;
        private decimal _calper;
        private decimal _bonusper;
        private string _date;
        private long _customerid;
        public virtual string Code
        {
            get { return _code; }
            set
            {
                if (_code == value)
                    return;
                _code = value;
                if (!PropertyUpdated.Contains("Code"))
                    PropertyUpdated.Add("Code");
            }
        }
        public virtual long CustomerId
        {
            get { return _customerid; }
            set
            {
                if (_customerid == value)
                    return;
                _customerid = value;
                if (!PropertyUpdated.Contains("CustomerId"))
                    PropertyUpdated.Add("CustomerId");
            }
        }
        public virtual long OrderId
        {
            get { return _orderid; }
            set
            {
                if (_orderid == value)
                    return;
                _orderid = value;
                if (!PropertyUpdated.Contains("OrderId"))
                    PropertyUpdated.Add("OrderId");
            }
        }
        public virtual long SalesId
        {
            get { return _salesid; }
            set
            {
                if (_salesid == value)
                    return;
                _salesid = value;
                if (!PropertyUpdated.Contains("SalesId"))
                    PropertyUpdated.Add("SalesId");
            }
        }
        public virtual decimal Bonus
        {
            get { return _bonus; }
            set
            {
                if (_bonus == value)
                    return;
                _bonus = value;
                if (!PropertyUpdated.Contains("Bonus"))
                    PropertyUpdated.Add("Bonus");
            }
        }
        public virtual decimal BonusPer
        {
            get { return _bonusper; }
            set
            {
                if (_bonusper == value)
                    return;
                _bonusper = value;
                if (!PropertyUpdated.Contains("BonusPer"))
                    PropertyUpdated.Add("BonusPer");
            }
        }
        public virtual decimal CalBase
        {
            get { return _calbase; }
            set
            {
                if (_calbase == value)
                    return;
                _calbase = value;
                if (!PropertyUpdated.Contains("CalBase"))
                    PropertyUpdated.Add("CalBase");
            }
        }
        public virtual decimal CalPer
        {
            get { return _calper; }
            set
            {
                if (_calper == value)
                    return;
                _calper = value;
                if (!PropertyUpdated.Contains("CalPer"))
                    PropertyUpdated.Add("CalPer");
            }
        }
        public virtual string Date
        {
            get { return _date; }
            set
            {
                if (_date == value)
                    return;
                _date = value;
                if (!PropertyUpdated.Contains("Date"))
                    PropertyUpdated.Add("Date");
            }
        }
    }
}
